﻿/* 头部容器 */
/*header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 60px;
    background-color: #2c3e50;*/ /* 背景色 */
    /*color: white;
    position: sticky;
    top: 0;
    z-index: 19;
    box-shadow: 0px 0px 10px 1px rgba(0, 0, 0, 0.1);
    width: 1500px;
}*/

    /* Logo 区域 */
    /*header .logo {
        display: flex;
        align-items: center;
    }

        header .logo img {
            max-width: 40px;*/ /* 调整 Logo 尺寸 */
            /*height: auto;
            margin-right: 10px;*/ /* Logo 与文字之间的间距 */
        /*}*/

/* 导航菜单 */
/*.divnav {
    display: flex;
    justify-content: center;
    flex-grow: 1;
}

    .divnav .nav {
        display: flex;
        gap: 15px;*/ /* 菜单项之间的间距 */
    /*}

        .divnav .nav li {
            list-style: none;
        }

            .divnav .nav li a {
                color: white;
                font-size: 15px;
                text-decoration: none;
                padding: 10px 5px;
                transition: color 0.3s ease;
            }

                .divnav .nav li a:hover {
                    color: #5184eb;*/ /* 悬停效果 */
                /*}*/

/* 个人资料区域（如用户头像和选项） */
/*.header-profile {
    display: flex;
    align-items: center;
    gap: 10px;*/ /* 图标和文字之间的间距 */
/*}

    .header-profile img {
        width: 30px;
        height: 30px;
        border-radius: 50%;*/ /* 圆形头像 */
    /*}

    .header-profile a {
        color: white;
        text-decoration: none;
        font-size: 14px;
    }*/

/* 响应式调整 */
/*@media screen and (max-width: 768px) {
    header {
        padding: 0 10px;
    }

    .divnav .nav {
        gap: 10px;
    }

        .divnav .nav li a {
            font-size: 13px;
            padding: 8px 5px;
        }
}

@media screen and (max-width: 480px) {
    header {
        flex-direction: column;
        padding: 10px;
        height: auto;
    }

    .divnav .nav {
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }

    .header-profile {
        margin-top: 10px;
        margin-left:20px;
    }


}*/

/*#son {
    background: linear-gradient(135deg, #89f7fe, #66a6ff);*/ /* 渐变的蓝色系背景 */
    /*padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.2);*/ /* 更明显的阴影效果 */
    /*color: #ffffff;
}*/

/*#son {
    background: black;
    overflow: hidden;
    padding: 20px;
    color: #ffffff;
    position: relative;
    border-radius: 8px;
}

    #son::before {
        content: "";
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: radial-gradient(circle, rgba(255, 255, 255, 0.5) 1px, transparent 1px);
        background-size: 10px 10px;
        opacity: 0.3;
        animation: starry 20s linear infinite;
    }

@keyframes starry {
    from {
        transform: translate(0, 0);
    }

    to {
        transform: translate(-50%, -50%);
    }
}*/
/* 头部容器 */
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 60px;
    background-color: #2c3e50;
    color: white;
    position: sticky;
    top: 0;
    z-index: 19;
    box-shadow: 0px 0px 10px 1px rgba(0, 0, 0, 0.1);
    width: 100%;
    /*max-width: 100%;*/
    margin: 0 auto; /* 居中对齐大屏幕 */
}

    /* Logo 区域 */
    header .logo {
        display: flex;
        align-items: center;
    }

        header .logo img {
            max-width: 40px;
            height: auto;
            margin-right: 10px;
        }

/* 导航菜单 */
.divnav {
    display: flex;
    justify-content: center;
    flex-grow: 1;
    overflow: hidden;
}

    .divnav .nav {
        display: flex;
        gap: 15px;
        flex-wrap: wrap; /* 当空间不够时自动换行 */
    }

        .divnav .nav li {
            list-style: none;
        }

            .divnav .nav li a {
                color: white;
                font-size: 15px;
                text-decoration: none;
                padding: 10px 5px;
                transition: color 0.3s ease;
            }

                .divnav .nav li a:hover {
                    color: #5184eb;
                }

/* 个人资料区域 */
.header-profile {
    display: flex;
    align-items: center;
    gap: 10px;
}

    .header-profile img {
        width: 30px;
        height: 30px;
        border-radius: 50%;
    }

    .header-profile a {
        color: white;
        text-decoration: none;
        font-size: 14px;
    }

/* 响应式调整 */

/* 平板设备 */
@media screen and (max-width: 1024px) {
    .divnav .nav {
        gap: 10px;
    }

        .divnav .nav li a {
            font-size: 14px;
            padding: 8px 5px;
        }

    .header-profile a {
        font-size: 13px;
    }
}

/* 移动设备 */
@media screen and (max-width: 768px) {
    header {
        padding: 0 15px;
    }

    .divnav .nav {
        gap: 8px;
        flex-wrap: wrap; /* 自动换行以适应屏幕 */
    }

        .divnav .nav li a {
            font-size: 13px;
            padding: 8px 4px;
        }

    .header-profile a {
        font-size: 12px;
    }
}

/* 小屏幕和极小屏幕 */
@media screen and (max-width: 480px) {
    header {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px;
        height: auto;
    }

    .logo {
        margin-bottom: 10px;
    }

    .divnav {
        justify-content: flex-start;
        width: 100%;
    }

        .divnav .nav {
            flex-direction: column;
            align-items: flex-start;
            gap: 5px;
        }

    .header-profile {
        margin-top: 10px;
        align-self: flex-end;
    }

        .header-profile a {
            font-size: 12px;
        }

}
/* 大屏幕 */
@media screen and (min-width: 1600px) {
    header {
        padding: 0 40px; /* 增加左右间距 */
    }

    .divnav .nav {
        gap: 25px; /* 增加菜单间距 */
    }

        .divnav .nav li a {
            font-size: 17px; /* 增大字体 */
            padding: 12px 8px; /* 增加内边距 */
        }

    .header-profile a {
        font-size: 15px;
    }
}

#parent {

position:relative;
}
#son {
    background-color: #000; /* 黑色背景，模拟夜空 */
    padding: 20px;
    color: #ffffff;
    position: relative;
    overflow: hidden;
    height: 100vh; /* 设置整个页面的高度 */
    overflow: auto; /* 允许内容超出时滚动 */
    font-family: 'Courier New', monospace;
}

    .rain {
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        color: #00ff00; /* 绿色的代码字体 */
        font-size: 18px; /* 字符大小 */
        white-space: nowrap;
        opacity: 0.8; /* 使代码更加透明 */
        animation: rain-animation 3s linear infinite;
    }

    /* 定义代码雨动画 */
    @keyframes rain-animation {
        0% {
            transform: translateY(-100%); /* 从屏幕上方开始 */
        }

        100% {
            transform: translateY(100vh); /* 到达屏幕下方 */
        }
    }

    @keyframes flicker {
        0% {
            opacity: 0.8;
        }

        50% {
            opacity: 1;
        }

        100% {
            opacity: 0.8;
        }
    }
/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


.open-modal-btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

    .open-modal-btn:hover {
        background-color: #0056b3;
    }

.registerModal {
    display: none; /* 默认隐藏 */
    position: absolute;
    /* left: 50%;
    bottom: 0;
    transform: translate(-50%,-50%);*/
    background-color: rgba(0, 0, 0, 0.5); /* 半透明背景遮罩 */
    width: 100%; /* 占满屏幕宽度 */
    height: 100%; /* 占满屏幕高度 */
    /*width: 800px;*/
}
/* 弹窗样式 */
.modal {
    display: none; /* 默认隐藏 */
    position: absolute;
    /* left: 50%;
    bottom: 0;
    transform: translate(-50%,-50%);*/
    background-color: rgba(0, 0, 0, 0.5); /* 半透明背景遮罩 */
    width: 100%; /* 占满屏幕宽度 */
    height: 100%; /* 占满屏幕高度 */
    /*width: 800px;*/
}

.modal-content {
    background-color: white;
    /*width: 800px;*/
    border-radius: 10px;
    padding: 20px;
    position: relative;
    animation: fadeIn 0.3s ease;
}

/* 弹窗出现动画 */
@keyframes fadeIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 关闭按钮 */
.close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 20px;
    cursor: pointer;
    color: gray;
}

    .close-btn:hover {
        color: black;
    }

/* 登录卡片 */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.login-card {
    display: flex;
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    width: 100%;
}

/* 左侧图像部分 */
.login-image {
    flex: 1;
    /*background-color: #f7f7f7;*/
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

    .login-image img {
        width: 100%;
        max-width: 300px;
        border-radius: 10px;
    }

/* 右侧表单部分 */
.login-form {
    flex: 1;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

    .login-form h2 {
        margin-bottom: 20px;
        font-size: 24px;
        color: #333;
        text-align: center;
    }

/* 表单元素 */
.form-group {
    margin-bottom: 20px;
   /* background:red;*/
    
}
    .form-group #rememberMe {
        width: 50px;
        font-size: 16px;
        border: 1px solid #ccc;
        border-radius: 5px;
    }
    .form-group input {
        width: 100%;
        padding: 10px 15px;
        font-size: 16px;
        border: 1px solid #ccc;
        border-radius: 5px;
    }

.password-group {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 16px;
    color: #666;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 5px;
}

    .remember-me input {
        margin: 0;
    }

    .remember-me label {
        font-size: 14px;
        color: #666;
    }

/* 登录按钮 */
.submit-btn {
    width: 100%;
    background-color: #007bff;
    color: white;
    padding: 10px;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

    .submit-btn:hover {
        background-color: #c72f3b;
    }

#nickName {
    border: none;
    background-color: #2c3e50;
    width: 50px;
    color: #fff;
}

.header-profile {
    position: relative;
    display: flex;
    align-items: center;
    gap: 15px;
}

.dropdown {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

.dropbtn {
    background: none;
    border: none;
    color: #666;
    font-size: 16px;
    cursor: pointer;
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    background-color: #fff;
    min-width: 120px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.2);
    z-index: 1;
}

    .dropdown-content a {
        color: black;
        padding: 12px 16px;
        text-decoration: none;
        display: block;
    }

.dropdown:hover .dropdown-content {
    display: block;
}